package com.aaa.service.impl;

import com.aaa.entity.Department;
import com.aaa.mapper.DepartmentMapper;
import com.aaa.service.DeptService;
import com.aaa.vo.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class DeptServiceImpl implements DeptService {
    @Autowired
    private DepartmentMapper departmentMapper;
    @Override
    public R findAll() {
        List<Department> departments = departmentMapper.selectAll();
        return new R(200,"查询成功",departments);
    }
}
